package com.cake.liulanxiangzhu.service;

import com.cake.liulanxiangzhu.pojo.dto.CakeProductDTO;
import com.cake.liulanxiangzhu.pojo.dto.CakeProductInsertDTO;
import com.cake.liulanxiangzhu.pojo.vo.CakeProductVO;
import com.cake.liulanxiangzhu.web.JsonPage;
import com.cake.liulanxiangzhu.web.JsonResult;

import java.util.List;


public interface ICakeProductService {

    String CAKE = "cake:";

    String CAKE_PMS = CAKE+"pms";

    void addCake(CakeProductInsertDTO cakeProductInsertDTO );

    /**
     *
     * <span> 分页显示所有甜品信息
     * @param page
     * @param pageSize
     * @return JsonPage<CakeProductVO>
     * @author dinghao
     * @date 2023/1/7 13:32
     */
    JsonPage<CakeProductVO> allCakes(Integer page , Integer pageSize );

    /**
     @Description: 查询所有甜品信息
     @Param: []
     @return: List<CakeProductVO>
     @Author: ManolinCoder
     @Date: 2023/1/19
     */
    List<CakeProductVO>  listSpu();


    /**
     *
     * <span>删除甜品信息
     * @param cakeId
     * @return void
     * @author dinghao
     * @date 2023/1/7 13:33
     */
    void deleteCake(Integer cakeId );

    /**
     *
     * <span> 修改甜品信息
     * @param cakeProductDTO
     * @return
     * @author dinghao
     * @date 2023/1/7 17:26
     */
    void updateCake(CakeProductDTO cakeProductDTO , Integer cakeId );

    /**
     *
     * <span> 下架商品
     * @param cakeId
     * @return void
     * @author dinghao
     * @date 2023/1/7 17:48
     */
    void updateDownPublished(Integer cakeId );

    /**
     *
     * <span> 上架商品
     * @param cakeId
     * @return void
     * @author dinghao
     * @date 2023/1/7 18:30
     */
    void updateSendPublished(Integer cakeId );

    /**
     *
     * <span> 根据ID查询甜品信息
     * @param cakeId
     * @return JsonResult<CakeProductVO>
     * @author dinghao
     * @date 2023/1/8 22:20
     */
    CakeProductVO queryCake(Integer cakeId);

    /**
     @Description: 热销榜单，排名前3的产品
     @Param: []
     @return: List<CakeProductVO>
     @Author: ManolinCoder
     @Date: 2023/1/25
     */
    List<CakeProductVO>  querySale();


    List<CakeProductVO>  queryPms(Integer categoryId);


    List<CakeProductVO>  queryProductByCategoryId(Integer categoryId );








}
